package com.qf.service;

import com.qf.mapper.EmpMapper;
import com.qf.pojo.Emp;

import java.io.FileNotFoundException;
import java.util.List;

/**
 * @author lixu
 */

public class EmpServiceImpl implements EmpService{

    private EmpMapper empMapper;
    public EmpServiceImpl(EmpMapper empMapper) {
        this.empMapper = empMapper;
    }

    @Override
    public List<Emp> findAll() {
        return empMapper.findAll();
    }
    public void addEmp(Emp emp) throws Exception{

        empMapper.addEmp(emp);
        Thread.sleep(4000);
 /*       if(null == null){
            throw new FileNotFoundException();
        }*/
        empMapper.update(emp);
        int i = 1/0;


    }
    public void addEEE(){


    }
    public void updateEmp(){


    }
    public void deleteById(){


    }
    public void insertEmp(){


    }
    public void saveEmp(){


    }
}
